<link type="text/css" href="/admins/js/jquery/css/ui-lightness/jquery-ui-1.8.20.custom.css" rel="stylesheet" />
<script type="text/javascript" src="/admins/js/My97DatePicker/WdatePicker.js"></script>
<div class="admin_nrtop">
      <div class="ad_search">
      </div>
</div>
<div  class="biaoge">
      <div class="biaotbody">
            <table >
                  <tr>
                        <th class="li6" style="text-align:center">
                              日期
                        </th>
                        <th class="li6" style="text-align:center;">
                              类型 
                        </th>
                        <th class="li6" style="text-align:center;">
                              关联单号
                        </th>
                        <th class="li6" style="text-align:center;">
                              创建人
                        </th>
                        <th class="li10" style="text-align:center;">
                              标题
                        </th>
                        <th class="li6" style="text-align:center;">
                              状态
                        </th>
                        <th class="li10" style="text-align:center;">
                              操作
                        </th>
                  </tr>
            </table>
      </div>
      <div class="table2">
            <?php
            if ($this->objlist) {
                  foreach ($this->objlist as $key => $Item) {
                        ?>

                        <div class="tablebox">
                              <table>
                                    <tr class="trhui">
                                          <td colspan="6" >
                                          </td>
                                          <td class="li205"><div class="lijz"><input type="checkbox" value="" class="checkbox-del" name='checkbox' /></div></td>
                                    </tr>
                                    <tr>
                                          <td class="li6" align="center"><?= $Item->dateCreated ?></td>
                                          <td class="li6" align="center">
                                                <div class="yubm"><a href="/admini/todotask/detail/id/<?php echo $Item->id; ?>">
                                                            <?php echo $Item->ObjectName->name ?>
                                                      </a></div>
                                          </td>
                                          <td class="li6" align="center"><?php echo $Item->objectType; ?></td>
                                          <td class="li6" style="text-align:center;"><?php echo $Item->UserName?$Item->UserName->nikename:''; ?></td>
                                          <td class="li10" style="text-align:center;"><?php echo $Item->content; ?></td>
                                          <td class="li6" align="center"><?php echo $Item->ObjectStatus; ?>
                                          </td>
                                          <td class="li10">
                                                <table >
                                                      <tr>
                                                            <th width="25%" style="text-align:center;">
                                                                   <?php 
                                                                  if($Item->status == 1){echo "<a href='{$this->list}status/{$Item->id}'>";echo'开始</a>';}
                                                                  else if($Item->status == 2){
                                                                        echo "<a href='{$this->list}status/{$Item->id}'>";echo'完成</a>';
                                                                  }
                                                                  else{
                                                                        echo'';
                                                                  }
                                                                  ?>
                                                                  </th>
                                                                  <th width="25%" style="text-align:center;">分配</th>
                                                                  <th width="25%" style="text-align:center;">修改</th>
                                                                  <th width="25%" style="text-align:center;">删除</th>
                                                      </tr>
                                                </table>
                                          </td>
                                    </tr>
                              </table>
                        </div>
                  <?php
                  }
            } else {
                  echo '<div class="tablebox">暂时无数据</div>';
            }
            ?>
      </div>
</div>
<div class="toolbar">
      <div class="qunx">
            <ul>
                  <li><a class="anvbotton" href="/admini/managewaybill/outstorage" id="printOut" name="printOut"><span>添加事项</span></a></li>
                  <li><a class="anvbotton" href="javascript:void(0)" id="AffirmChannel" name="AffirmChannel"><span>删除</span></a></li>
<!--                        <li><a class="anvbotton4" href="javascript:void(0)" id="ckall" name="ckall"><span></span></a></li>-->
            </ul>
      </div>
</div>
<div class="tanchuang" style="display:none;">
      <div class="nui-msgbox">
            <div class="nui-msgbox-hd" id="uuchInterior">悠奇内部备注</div>
            <a class="nui-msgbox-close" title="关闭"><b></b></a>
      </div>
      <div class="wenti_box" id="problemComm">
            <div class="wt_center" style="height:350px;">

            </div>
            <div class="wt_caozuo">
                  <textarea name="wayRemark" cols="" rows="" id="wayRemark"></textarea>
                  <input type="hidden" id="addRemarkWayId" name="addRemarkWayId" value=""/>
                  <a class="wt_liuyan" href="javascript:void(0)" id="addIndexRemark"><span>留言</span></a>
            </div>
      </div>    
</div>
<div class="houtai_overlay" style="display:none;"></div>
<table>    
      <tfoot>
            <tr>
                  <td colspan="2">　
                  </td></tr>
      </tfoot>    
</table>
<?php echo $this->name?>
<div class="toolbar">
    <?php echo $this->partial('paging.phtml', array("pages" => $this->objAll,"pamas"=>"name=".$this->name)); ?>
</div>
<script type="text/javascript">
      $(document).ready(function() {
            $(".dian").mouseenter(function() {
                  $(this).next("div").attr("style", "display:block;");
            });
            $(".bzloading").mouseleave(function() {
                  $(".bzloading .bzxiangbox").attr("style", "display:none;");
            });
            $("#start_point").click(function() {
                  $.post(
                          "/admini/todotask/track/",
                          {
                                idlist: "<?php echo $this->objectall->id ?>",
                                objectId: "<?php echo$this->objectall->objectId ?>",
                                objectType: "<?php echo$this->objectall->objectType ?>",
                                content: $("#zhipai_detail").val(),
                                trackcur: "1",
                                operateType: "<?php echo$this->objectall->status ?>",
                                operator: $('#zhipai').val()
                          },
                  function(data) {
                        alert('指派成功！');
                        location.reload();
                  });
            });
</script>
